<?php

namespace App\Http\Controllers;

use App\Http\Resources\BaseResource;
use App\Repositories\Policy\Contracts\HbGjPolicyInterface;
use Illuminate\Http\Request;

class RefundController
{
    public function canRefund(){

        return view('refund.canrefund');
    }

    public function ajaxCanRefund(Request $request,HbGjPolicyInterface $hbGjPolicyInterface){

        $param = [
            'orderId' => $request->orderId,
            'ticketIds' => explode(',',$request->ticketIds)
        ];
        $res = $hbGjPolicyInterface->canRefund($param);
        return $res;
    }
}